<template>
     <div class="hot-search">
      <h2>热门搜索</h2>
      <div class="hot-search-list">
          <van-tag text-color="red"  plain  @click="hisSearch('520元红包抢先领')">520元红包抢先领</van-tag>
          <van-tag text-color="#666" plain  @click="hisSearch('单鞋')">单鞋</van-tag>
          <van-tag text-color="#666" plain  @click="hisSearch('墨镜')">墨镜</van-tag>
          <van-tag text-color="#666" plain  @click="hisSearch('夏凉被')">夏凉被</van-tag>
          <van-tag text-color="#666" plain  @click="hisSearch('新品上市')">新品上市</van-tag>
          <van-tag text-color="#666" plain  @click="hisSearch('日式')">日式</van-tag>
          <van-tag text-color="#666" plain  @click="hisSearch('母亲节')">母亲节</van-tag>
      </div>  
  </div> 
</template>

<script>
    export default {
        name:'HotSearch',
        methods: {
             hisSearch(title){
                this.$bus.$emit('addSearch',title);
            },
        },
    }
</script>

<style scoped>
    .hot-search{
        width: 100%;
        background-color: white;
        margin-top:20px;
    }
    h2{
        padding: 10px;
        margin: 0;
        text-align: left;
        margin-left: 20px;
    }
    .hot-search-list{
        text-align: left;
        margin-left: 20px;
    }
    .hot-search-list>span{
        margin: 5px;
    }
</style>